// 业绩提成-详情-回款列表table
export const receivableDetailsList = info => {
  return [
    {
      label: '回款单号',
      prop: 'returnedNo',
      minWidth: 120
    },
    {
      prop: 'customerName',
      label: '关联客户',
      render: (h, row) => {
        return [
          <el-button
            type="text"
            onClick={() => {
              info.onExtendShow(row.customerId, 'customer')
            }}
          >
            {row.customerName}
          </el-button>
        ]
      }
    },
    {
      prop: 'saleOrderNo',
      label: '关联销售单',
      render: (h, row) => {
        return [
          <el-button
            type="text"
            onClick={() => {
              info.onExtendShow(row.saleId, 'sale')
            }}
          >
            {row.saleOrderNo}
          </el-button>
        ]
      }
    },
    {
      label: '回款日期',
      prop: 'returnedTime'
    },
    {
      label: '回款金额(元)',
      prop: 'returnedMoney'
    },
    {
      label: '账期(天)',
      prop: 'paymentDays'
    },
    {
      label: '逾期天数(元)',
      prop: 'overdueDay'
    },
    {
      label: '应发提成(元)',
      prop: 'returnedPrice'
    },
    {
      label: '核发提成(元)',
      prop: 'verifyPrice',
      width: 120,
      render: (h, row) => {
        return (
          info.infoObj.status === '0'
            ? <div></div>
            : <div class={row.verifyPrice !== row.returnedPrice ? 'fc-error mr5 fs12' : 'fc-normal mr5 fs12'}>{row.verifyPrice}</div>
        )
      }
    }
  ]
}
